<?php 
include_once 'connection/connection_database.php';
include_once 'app/model/category/process.php';
include_once 'app/model/board/process.php';
include_once 'app/model/banner/process.php';
include_once 'app/model/hotline/process.php';
$categories = new Categories();
$board = new Boards();
$banner = new Banner();
$hotline = new HotLine();

$result = $categories->FillAll();
$bannerTop = $banner->FillBannerTop();
$fillHotLine = mysql_fetch_array($hotline->FillAll());
?>
<div id="topmenu">
    <ul id="tab">
        <li><a href="<?php echo $url["home"] ?>/index.html"><span>Trang chủ</span></a></li>
        <li><a href="<?php echo $url["home"] ?>/lien-he.html"><span>Liên hệ</span></a></li>
        <li><a href="<?php echo $url["home"] ?>/ve-chung-toi.html"><span>Về chúng tôi</span></a></li>
        <li><a href="<?php echo $url["home"] ?>/danh-sach-cau-hoi.html"><span>Tư vấn luật</span></a></li>
        <li><a href="<?php echo $url["home"] ?>/rss"><span>RSS</span></a></li>
    </ul>
    <div class="hotline">
        <marquee behavior="scroll" direction="left" onmouseover="this.stop();" onmouseout="this.start();">Hotline: <?php echo $fillHotLine["hotline_phone"] ?></marquee>
    </div><!--End .hotline-->
    <div class="clear"></div>
</div><!--End #topmenu-->
<div id="logo">
	<div>
       <h1>Thành lập công ty, Sở hữu trí tuệ, Xin giấy phép, Dịch vụ kế toán</h1>
       <a href="<?php echo $url["home"] ?>/index.html" title="Công ty TNHH tư vấn Bravo" ><img src="<?php echo $bannerTop["banner_url"] ?>" alt="Công ty TNHH tư vấn Bravo" width="1002px" height="170px"/></a>
    </div>
    <div class="search">
        <form action="search" method="post" name="frmSearch">
            <input type="text" name="txtData" id="txtData" value="Nhập từ tìm kiếm..." onblur="if (this.value=='') this.value='Nhập từ tìm kiếm...';" onfocus="if (this.value=='Nhập từ tìm kiếm...') this.value='';"/>
            <input type="submit" name="btnSearch" onclick="this.frmSearch.txtData.focus();" value=" ">
        </form>
    </div>
</div><!--End #logo-->
<div id="navigation">         
    <ul id="nav">
        <li><a href="<?php echo $url["home"] ?>/index.html"  <?php if($menu == "") echo 'class="current_page"';  ?> >Trang chủ</a></li>
        <?php 
            while($rows = mysql_fetch_array($result)) { 
            $resultBoard = $board->FillAll($rows["category_id"]);    
        ?>
            <li><a href="<?= $rows["category_url"] ?>"><?= $rows["category_name"] ?><img src="<?php echo $url["home"] ?>/images/darrow.png" alt="down-menu" /></a>
                <ul>
                    <?php while($rowBoard = mysql_fetch_array($resultBoard)) { ?>
                        <li><a href="<?php echo $url["home"]."/".$rowBoard["board_url"].".html" ?>"><img src="<?php echo $url["home"] ?>/images/rarrow.png" alt="bullet-menu" /><?= $rowBoard["board_name"] ?></a></li>
                   <?php } ?> 
                </ul>
            </li>
        <?php } ?>
    </ul><!--End .jq-menu-->
</div><!--End #navigation-->